Skip to content

Add chocolatey management support#60

Merged
myii merged 4 commits into
saltstack-formulas:masterfrom
kartnico:chocolatey
Mar 30, 2020
Merged

Add chocolatey management support#60
myii merged 4 commits into
saltstack-formulas:masterfrom
kartnico:chocolatey

Conversation

@kartnico

Copy link
Copy Markdown

This PR permits to manage packages with Chocolatey Salt module here

@noelmcloughlin noelmcloughlin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution @kartnico LGTM

@aboe76

aboe76 commented Sep 18, 2019

Copy link
Copy Markdown
Contributor

@noelmcloughlin what about the tests?

@noelmcloughlin

Copy link
Copy Markdown
Contributor

I thought about that but chocloatey only works on Windows platform. Is there any example where we have formula running on travis/windows?

@javierbertoli

Copy link
Copy Markdown
Member

Does travis provide Windows/chocolatey testing support? Otherwise, we should try to skip those tests

@noelmcloughlin

noelmcloughlin commented Sep 18, 2019

Copy link
Copy Markdown
Contributor

I found this: https://docs.travis-ci.com/user/reference/windows

Take note that our Windows environment is in early stages and a minimal subset of what’s available on Linux or macOS is currently supported.

@kartnico would you be interested in investigating Travis/Windows support for this community? This is something we are missing I think.

Chocolatey, the package manager for Windows, is installed and can be used to install Windows packages.

@kartnico

Copy link
Copy Markdown
Author

Hello,

If you want to use Travis with Kitchen and Inspec on Windows, I have not found how to do it with Travis.

On the other hand, other communities seem to use AppVeyor for this : https://github.com/chocolatey/chocolatey-cookbook

https://www.hurryupandwait.io/blog/run-kitchen-tests-in-travis-and-appveyor-using-the-kitchen-machine-driver

What do you think about using AppVeyor ?

Regards,

Nicolas

@noelmcloughlin

Copy link
Copy Markdown
Contributor

@myii fyi

@aboe76

aboe76 commented Sep 25, 2019

Copy link
Copy Markdown
Contributor

@noelmcloughlin maybe cirrus ci?

@myii

myii commented Sep 25, 2019

Copy link
Copy Markdown
Contributor

This PR and specific comment is of relevance:

Cirrus-CI has Windows containers available but I'm not sure how useful they will be:

@noelmcloughlin

Copy link
Copy Markdown
Contributor

from saltstack-formulas/openvpn-formula#112 (comment)

files cannot be uploaded to the container while it's running

Hi @myii could you explain the issue further particularly regarding this sentence? thanks.

@myii

myii commented Sep 25, 2019

Copy link
Copy Markdown
Contributor

@noelmcloughlin That would be @dafyddj we'd need to get a specific response from re: saltstack-formulas/openvpn-formula#112 (comment).

@noelmcloughlin

Copy link
Copy Markdown
Contributor

@kartnico asked a specific question too-

What do you think about using AppVeyor ?

We probably need a dedicated issue for windows CI since it bigger scope that this PR.

@myii

myii commented Sep 26, 2019

Copy link
Copy Markdown
Contributor

What do you think about using AppVeyor ?

The issue here is the time it will require to do all of the research and testing. Then it would need to be discussed with the core team, to see if it can be included. If anyone wants to take that on, that would be great.

In the meantime, we could at least get local testing working, based upon kitchen-vagrant. Again, hopefully someone can find the time to invest into this.

@myii

myii commented Sep 26, 2019

Copy link
Copy Markdown
Contributor

For the time being, in order for this PR to be considered for merging, the tests need to be skipped, as mentioned by @javierbertoli. @kartnico Are you able to do that?


Essentially, just wrap packages/chocolatey.sls with a Jinja if block to only run on Windows systems.

@dafyddj

dafyddj commented Sep 26, 2019

Copy link
Copy Markdown
Contributor

from saltstack-formulas/openvpn-formula#112 (comment)

files cannot be uploaded to the container while it's running

Hi @myii could you explain the issue further particularly regarding this sentence? thanks.

The only real reference I can find on this is on Stack Overflow.
It seems to have something to do with running on Windows 10 (which I was doing).
But kitchen-salt and/or kitchen-docker depend on copying state and pillar files to the guest/test container while it's running, ruling out Windows containers running on Windows 10 at least, until some other file transfer method can be implemented.

@noelmcloughlin

Copy link
Copy Markdown
Contributor

wrap packages/chocolatey.sls with a Jinja if block to only run on Windows systems.

@kartnico can you do that.

@kartnico

Copy link
Copy Markdown
Author

@noelmcloughlin done !

@noelmcloughlin

Copy link
Copy Markdown
Contributor

Thanks @kartnico I've approved the PR but can you fix the conflicts, please?

@myii

myii commented Mar 30, 2020

Copy link
Copy Markdown
Contributor

@kartnico Don't worry, I've fixed the conflicts and rebased this PR, including adjusting the commit messages in accordance with semantic-release. I'll merge this as soon as the tests pass.

CC: @noelmcloughlin.

@myii myii merged commit 9a9d3e4 into saltstack-formulas:master Mar 30, 2020
@myii

myii commented Mar 30, 2020

Copy link
Copy Markdown
Contributor

Merged, thanks for the patience @kartnico!

@saltstack-formulas-travis

Copy link
Copy Markdown

🎉 This PR is included in version 0.10.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@myii

myii commented Mar 29, 2021

Copy link
Copy Markdown
Contributor

Hello,

If you want to use Travis with Kitchen and Inspec on Windows, I have not found how to do it with Travis.

On the other hand, other communities seem to use AppVeyor for this : https://github.com/chocolatey/chocolatey-cookbook

https://www.hurryupandwait.io/blog/run-kitchen-tests-in-travis-and-appveyor-using-the-kitchen-machine-driver

What do you think about using AppVeyor ?

Regards,

Nicolas

@kartnico The good news is that we've got Windows testing taking place in GitHub Actions for this formula now. For versions 8.1, 2016 and 2019.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants